LanguageExt.Core

LanguageExt.Core Class Instances

If you're new to this library or functional-programming this is almost certainly not the place to start browsing!

Class-instances try to replicate the instances of Haskell in C#. They pair with the type-classes using ad-hoc polymorphism.

Ad-hoc polymorphism has long been believed to not be possible in C#. However with some cunning it is. Ad-hoc polymorphism allows programmers to add traits to a type later. For example in C# it would be amazing if we had an interface called INumeric for numeric types like int, long, double, etc. The reason this doesn't exist is if you write a function like:

INumeric Add(INumeric x, INumeric y) => x + y;

Then it would cause boxing. Which is slow (well, slower). I can only assume that's why it wasn't added by the BCL team. Anyway, it's possible to create a numeric type, very much like a type-class in Haskell, and ad-hoc instances of the numeric type-class that allow for generic numeric operations without boxing. See the wiki for a deeper dive into ad-hoc polymorphism

Contents

Sub modules

Applicative
ClassFunctions
Const
Eq
EqAsync
Foldable
Functor
Hashable
HashableAsync
Indexable
Monad
Monoid
Ord
OrdAsync
Pred
Semigroup
Trans

class Class <A> Source #

Finds the default class instance for a type. So for Eq<string> it finds EqString. The result is cached so there's only a one time hit per type to resolve.

Parameters

type A

Fields

field string Name Source #

field IReadOnlyCollection<Type> All Source #

field Option<string> Error Source #

field A Default Source #

Default class instance. If this is null then one couldn't be found, or more that one was found.

class ClassInstancesAssembly Source #

Fields

field ClassInstancesAssembly singleton Source #

field List<Type> Types Source #

field List<Type> Structs Source #

field List<Type> AllClassInstances Source #

field Dict ClassInstances Source #

field Option<Exception> Error Source #

If the caching throws an error, this will be set.

Properties

property ClassInstancesAssembly Default Source #

Singleton access

Constructors

constructor ClassInstancesAssembly () Source #

Ctor

Methods

method Unit Initialise () Source #

Force the caching of class instances. If you run this at start-up then there's a much better chance the system will find all assemblies that have class instances in them. Not a requirement though.

struct TArr <A> Source #

Fields

Methods

method Arr<A> Append (Arr<A> x, Arr<A> y) Source #

method Arr<A> Empty () Source #

struct TArray <A> Source #

Fields

Methods

method A[] Append (A[] x, A[] y) Source #

method A[] Empty () Source #

struct TBigInt Source #

Integer number

Fields

Methods

method bool Equals (bigint x, bigint y) Source #

Equality test

Parameters

param x

The left hand side of the equality operation

param y

The right hand side of the equality operation

returns

True if x and y are equal

method int Compare (bigint x, bigint y) Source #

Compare two values

Parameters

param x

Left hand side of the compare operation

param y

Right hand side of the compare operation

returns

if x greater than y : 1

if x less than y : -1

if x equals y : 0

method bigint Plus (bigint x, bigint y) Source #

Find the sum of two numbers

Parameters

param x

left hand side of the addition operation

param y

right hand side of the addition operation

returns

The sum of x and y

method bigint Subtract (bigint x, bigint y) Source #

Find the difference between two values

Parameters

param x

left hand side of the subtraction operation

param y

right hand side of the subtraction operation

returns

The difference between x and y

method bigint Product (bigint x, bigint y) Source #

Find the product of two numbers

Parameters

param x

left hand side of the product operation

param y

right hand side of the product operation

returns

The product of x and y

method bigint Divide (bigint x, bigint y) Source #

Divide two numbers

Parameters

param x

left hand side of the division operation

param y

right hand side of the division operation

returns

x / y

method bigint Abs (bigint x) Source #

Find the absolute value of a number

Parameters

param x

The value to find the absolute value of

returns

The non-negative absolute value of x

method bigint Signum (bigint x) Source #

Find the sign of x

Parameters

param x

The value to find the sign of

returns

-1, 0, or +1

method bigint FromInteger (int x) Source #

Generate a numeric value from an integer

Parameters

param x

The integer to use

returns

The equivalent of x in the Num

method bigint FromDecimal (decimal x) Source #

Generate a numeric value from a float

Parameters

param x

The float to use

returns

The equivalent of x in the Num

method bigint FromFloat (float x) Source #

Generate a numeric value from a double

Parameters

param x

The double to use

returns

The equivalent of x in the Num

method bigint FromDouble (double x) Source #

Generate a numeric value from a decimal

Parameters

param x

The decimal to use

returns

The equivalent of x in the Num

method bigint Empty () Source #

Monoid empty value (0)

Parameters

returns

0

method bigint Negate (bigint x) Source #

Negate the value

Parameters

param x

Value to negate

returns

The negated source value

method bigint Append (bigint x, bigint y) Source #

Semigroup append (sum)

Parameters

param x

left hand side of the append operation

param y

right hand side of the append operation

returns

x + y

method int GetHashCode (bigint x) Source #

Get the hash-code of the provided value

Parameters

returns

Hash code of x

method bigint True () Source #

Returns True

Parameters

returns

True

method bigint False () Source #

Returns False

Parameters

returns

False

method bigint And (bigint a, bigint b) Source #

Returns the result of the bitwise AND operation between a and b

Parameters

returns

The result of the bitwise AND operation between a and b

method bigint Or (bigint a, bigint b) Source #

Returns the result of the bitwise OR operation between a and b

Parameters

returns

The result of the bitwise OR operation between a and b

method bigint Not (bigint a) Source #

Returns the result of the bitwise NOT operation on a

Parameters

returns

The result of the bitwise NOT operation on a

method bigint XOr (bigint a, bigint b) Source #

Returns the result of the bitwise exclusive-OR operation between a and b

Parameters

returns

The result of the bitwise exclusive-OR operation between a and b

method bigint Implies (bigint a, bigint b) Source #

Logical implication

Parameters

returns

If a is true that implies b, else true

method bigint BiCondition (bigint a, bigint b) Source #

Bitwise bi-conditional.

Parameters

returns

Not(XOr(a, b))

method Task<bool> EqualsAsync (bigint x, bigint y) Source #

method Task<int> GetHashCodeAsync (bigint x) Source #

method Task<int> CompareAsync (bigint x, bigint y) Source #

struct TBool Source #

Bool class instance. Implements

Eq<bool>
Ord<bool>
Bool<bool>

Fields

Methods

method bool And (bool a, bool b) Source #

Returns the result of the logical AND operation between a and b

Parameters

returns

The result of the logical AND operation between a and b

method int Compare (bool x, bool y) Source #

Compare two values

Parameters

param x

Left hand side of the compare operation

param y

Right hand side of the compare operation

returns

if x greater than y : 1

if x less than y : -1

if x equals y : 0

method bool Equals (bool x, bool y) Source #

Equality test

Parameters

param x

The left hand side of the equality operation

param y

The right hand side of the equality operation

returns

True if x and y are equal

method bool False () Source #

Returns False

Parameters

returns

False

method int GetHashCode (bool x) Source #

Get the hash-code of the provided value

Parameters

returns

Hash code of x

method bool Not (bool a) Source #

Returns the result of the logical NOT operation on a

Parameters

returns

The result of the logical NOT operation on a

method bool Or (bool a, bool b) Source #

Returns the result of the logical OR operation between a and b

Parameters

returns

The result of the logical OR operation between a and b

method bool True () Source #

Returns True

Parameters

returns

True

method bool XOr (bool a, bool b) Source #

Returns the result of the logical exclusive-OR operation between a and b

Parameters

returns

The result of the logical exclusive-OR operation between a and b

method bool Implies (bool a, bool b) Source #

Logical implication

Parameters

returns

If a is true that implies b, else true

method bool BiCondition (bool a, bool b) Source #

Logical bi-conditional. Both a and b must be true, or both a and b must be false.

Parameters

returns

true if a == b, false otherwise

method Task<bool> EqualsAsync (bool x, bool y) Source #

method Task<int> GetHashCodeAsync (bool x) Source #

method Task<int> CompareAsync (bool x, bool y) Source #

struct TBoolBool Source #

TBoolBool class instance. Implements

Eq<(bool, bool)>
Ord<(bool, bool)>
Bool<(bool, bool)>

Fields

Methods

method (bool, bool) And ((bool, bool) a, (bool, bool) b) Source #

Returns the result of the logical AND operation between a and b

Parameters

returns

The result of the logical AND operation between a and b

method int Compare ((bool, bool) x, (bool, bool) y) Source #

Compare two values

Parameters

param x

Left hand side of the compare operation

param y

Right hand side of the compare operation

returns

if x greater than y : 1

if x less than y : -1

if x equals y : 0

method bool Equals ((bool, bool) x, (bool, bool) y) Source #

Equality test

Parameters

param x

The left hand side of the equality operation

param y

The right hand side of the equality operation

returns

True if x and y are equal

method (bool, bool) False () Source #

Returns False

Parameters

returns

False

method int GetHashCode ((bool, bool) x) Source #

Get the hash-code of the provided value

Parameters

returns

Hash code of x

method (bool, bool) Not ((bool, bool) a) Source #

Returns the result of the logical NOT operation on a

Parameters

returns

The result of the logical NOT operation on a

method (bool, bool) Or ((bool, bool) a, (bool, bool) b) Source #

Returns the result of the logical OR operation between a and b

Parameters

returns

The result of the logical OR operation between a and b

method (bool, bool) True () Source #

Returns True

Parameters

returns

True

method (bool, bool) XOr ((bool, bool) a, (bool, bool) b) Source #

Returns the result of the logical exclusive-OR operation between a and b

Parameters

returns

The result of the logical exclusive-OR operation between a and b

method (bool, bool) Implies ((bool, bool) a, (bool, bool) b) Source #

Logical implication

Parameters

returns

If a is true that implies b, else true

method (bool, bool) BiCondition ((bool, bool) a, (bool, bool) b) Source #

Logical bi-conditional. Both a and b must be true, or both a and b must be false.

Parameters

returns

true if a == b, false otherwise

method Task<bool> EqualsAsync ((bool, bool) x, (bool, bool) y) Source #

method Task<int> GetHashCodeAsync ((bool, bool) x) Source #

method Task<int> CompareAsync ((bool, bool) x, (bool, bool) y) Source #

struct TChar Source #

Integer number

Fields

Methods

method bool Equals (char x, char y) Source #

Equality test

Parameters

param x

The left hand side of the equality operation

param y

The right hand side of the equality operation

returns

True if x and y are equal

method int Compare (char x, char y) Source #

Compare two values

Parameters

param x

Left hand side of the compare operation

param y

Right hand side of the compare operation

returns

if x greater than y : 1

if x less than y : -1

if x equals y : 0

method char Empty () Source #

Monoid empty value (0)

Parameters

returns

0

method char Append (char x, char y) Source #

Semigroup append (sum)

Parameters

param x

left hand side of the append operation

param y

right hand side of the append operation

returns

x + y

method int GetHashCode (char x) Source #

Get the hash-code of the provided value

Parameters

returns

Hash code of x

method char Plus (char x, char y) Source #

method char Subtract (char x, char y) Source #

method char Product (char x, char y) Source #

method char Negate (char x) Source #

method Task<bool> EqualsAsync (char x, char y) Source #

method Task<int> GetHashCodeAsync (char x) Source #

method Task<int> CompareAsync (char x, char y) Source #

struct TDecimal Source #

Fields

Methods

method bool Equals (decimal x, decimal y) Source #

Equality test

Parameters

param x

Left hand side of the equality operation

param y

Right hand side of the equality operation

returns

True if parameters are equal

method int Compare (decimal x, decimal y) Source #

Compare two values

Parameters

param x

Left hand side of the compare operation

param y

Right hand side of the compare operation

returns

if x greater than y : 1

if x less than y : -1

if x equals y : 0

method decimal Plus (decimal x, decimal y) Source #

Find the sum of two values

Parameters

param x

left hand side of the addition operation

param y

right hand side of the addition operation

returns

The sum of x and y

method decimal Subtract (decimal x, decimal y) Source #

Find the difference between two values

Parameters

param x

left hand side of the subtraction operation

param y

right hand side of the subtraction operation

returns

The difference between x and y

method decimal Product (decimal x, decimal y) Source #

Find the product of two values

Parameters

param x

left hand side of the product operation

param y

right hand side of the product operation

returns

The product of x and y

method decimal Divide (decimal x, decimal y) Source #

Divide two numbers

Parameters

param x

left hand side of the division operation

param y

right hand side of the division operation

returns

x / y

method decimal Abs (decimal x) Source #

Find the absolute value of a number

Parameters

param x

The value to find the absolute value of

returns

The non-negative absolute value of x

method decimal Signum (decimal x) Source #

Find the sign of x

Parameters

param x

The value to find the sign of

returns

-1, 0, or +1

method decimal FromInteger (int x) Source #

Generate a numeric value from an integer

Parameters

param x

The integer to use

returns

The equivalent of x in the Num

method decimal FromDecimal (decimal x) Source #

Generate a numeric value from a decimal

Parameters

param x

The decimal to use

returns

The equivalent of x in the Num

method decimal FromFloat (float x) Source #

Generate a numeric value from a float

Parameters

param x

The float to use

returns

The equivalent of x in the Num

method decimal FromDouble (double x) Source #

Generate a numeric value from a double

Parameters

param x

The double to use

returns

The equivalent of x in the Num

method decimal FromRational (Ratio<int> x) Source #

Generates a fractional value from an integer ratio.

Parameters

param x

The ratio to convert

returns

The equivalent of x in the implementing type.

method decimal Pi () Source #

Returns an approximation of pi.

Parameters

returns

A reasonable approximation of pi in this type

method decimal Exp (decimal x) Source #

The exponential function.

Parameters

param x

The value for which we are calculating the exponential

returns

method decimal Sqrt (decimal x) Source #

Calculates the square root of a value.

Parameters

param x

The value for which we are calculating the square root.

returns

.

method decimal Log (decimal x) Source #

Calculates the natural logarithm of a value.

Parameters

param x

The value for which we are calculating the natural logarithm.

returns

.

method decimal Pow (decimal x, decimal y) Source #

Raises x to the power y

Parameters

param x

The base to be raised to y

param y

The exponent to which we are raising x

returns

.

method decimal LogBase (decimal b, decimal x) Source #

Calculates the logarithm of a value with respect to an arbitrary base.

Parameters

param x

The base to use for the logarithm of t

param y

The value for which we are calculating the logarithm.

returns

.

method decimal Sin (decimal x) Source #

Calculates the sine of an angle.

Parameters

param x

An angle, in radians

returns

method decimal Cos (decimal x) Source #

Calculates the cosine of an angle.

Parameters

param x

An angle, in radians

returns

method decimal Tan (decimal x) Source #

Calculates the tangent of an angle.

Parameters

param x

An angle, in radians

returns

method decimal Asin (decimal x) Source #

Calculates an arcsine.

Parameters

param x

The value for which an arcsine is to be calculated.

returns

, in radians.

method decimal Acos (decimal x) Source #

Calculates an arc-cosine.

Parameters

param x

The value for which an arc-cosine is to be calculated

returns

, in radians

method decimal Atan (decimal x) Source #

Calculates an arc-tangent.

Parameters

param x

The value for which an arc-tangent is to be calculated

returns

, in radians

method decimal Sinh (decimal x) Source #

Calculates a hyperbolic sine.

Parameters

param x

The value for which a hyperbolic sine is to be calculated

returns

method decimal Cosh (decimal x) Source #

Calculates a hyperbolic cosine.

Parameters

param x

The value for which a hyperbolic cosine is to be calculated

returns

method decimal Tanh (decimal x) Source #

Calculates a hyperbolic tangent.

Parameters

param x

The value for which a hyperbolic tangent is to be calculated.

returns

method decimal Asinh (decimal x) Source #

Calculates an area hyperbolic sine

Parameters

param x

The value for which an area hyperbolic sine is to be calculated.

returns

.

method decimal Acosh (decimal x) Source #

Calculates an area hyperbolic cosine.

Parameters

param x

The value for which an area hyperbolic cosine is to be calculated.

returns

.

method decimal Atanh (decimal x) Source #

Calculates an area hyperbolic tangent.

Parameters

param x

The value for which an area hyperbolic tangent is to be calculated.

returns

method decimal Negate (decimal x) Source #

Negate the value

Parameters

param x

Value to negate

returns

The negated source value

method decimal Append (decimal x, decimal y) Source #

Semigroup append (sum)

Parameters

param x

left hand side of the append operation

param y

right hand side of the append operation

returns

x + y

method decimal Empty () Source #

Zero

method int GetHashCode (decimal x) Source #

Get the hash-code of the provided value

Parameters

returns

Hash code of x

method Task<bool> EqualsAsync (decimal x, decimal y) Source #

method Task<int> GetHashCodeAsync (decimal x) Source #

method Task<int> CompareAsync (decimal x, decimal y) Source #

struct TDouble Source #

Fields

Methods

method bool Equals (double x, double y) Source #

Equality test

Parameters

param x

Left hand side of the equality operation

param y

Right hand side of the equality operation

returns

True if parameters are equal

method int Compare (double x, double y) Source #

Compare two values

Parameters

param x

Left hand side of the compare operation

param y

Right hand side of the compare operation

returns

if x greater than y : 1

if x less than y : -1

if x equals y : 0

method double Plus (double x, double y) Source #

Find the sum of two values

Parameters

param x

left hand side of the addition operation

param y

right hand side of the addition operation

returns

The sum of x and y

method double Subtract (double x, double y) Source #

Find the difference between two values

Parameters

param x

left hand side of the subtraction operation

param y

right hand side of the subtraction operation

returns

The difference between x and y

method double Product (double x, double y) Source #

Find the product of two values

Parameters

param x

left hand side of the product operation

param y

right hand side of the product operation

returns

The product of x and y

method double Divide (double x, double y) Source #

Divide two numbers

Parameters

param x

left hand side of the division operation

param y

right hand side of the division operation

returns

x / y

method double Abs (double x) Source #

Find the absolute value of a number

Parameters

param x

The value to find the absolute value of

returns

The non-negative absolute value of x

method double Signum (double x) Source #

Find the sign of x

Parameters

param x

The value to find the sign of

returns

-1, 0, or +1

method double FromInteger (int x) Source #

Generate a numeric value from an integer

Parameters

param x

The integer to use

returns

The equivalent of x in the Num

method double FromDecimal (decimal x) Source #

Generate a numeric value from a decimal

Parameters

param x

The decimal to use

returns

The equivalent of x in the Num

method double FromFloat (float x) Source #

Generate a numeric value from a float

Parameters

param x

The float to use

returns

The equivalent of x in the Num

method double FromDouble (double x) Source #

Generate a numeric value from a double

Parameters

param x

The double to use

returns

The equivalent of x in the Num

method double FromRational (Ratio<int> x) Source #

Generates a fractional value from an integer ratio.

Parameters

param x

The ratio to convert

returns

The equivalent of x in the implementing type.

method double Pi () Source #

Returns an approximation of pi.

Parameters

returns

A reasonable approximation of pi in this type

method double Exp (double x) Source #

The exponential function.

Parameters

param x

The value for which we are calculating the exponential

returns

method double Sqrt (double x) Source #

Calculates the square root of a value.

Parameters

param x

The value for which we are calculating the square root.

returns

.

method double Log (double x) Source #

Calculates the natural logarithm of a value.

Parameters

param x

The value for which we are calculating the natural logarithm.

returns

.

method double Pow (double x, double y) Source #

Raises x to the power y

Parameters

param x

The base to be raised to y

param y

The exponent to which we are raising x

returns

.

method double LogBase (double b, double x) Source #

Calculates the logarithm of a value with respect to an arbitrary base.

Parameters

param x

The base to use for the logarithm of t

param y

The value for which we are calculating the logarithm.

returns

.

method double Sin (double x) Source #

Calculates the sine of an angle.

Parameters

param x

An angle, in radians

returns

method double Cos (double x) Source #

Calculates the cosine of an angle.

Parameters

param x

An angle, in radians

returns

method double Tan (double x) Source #

Calculates the tangent of an angle.

Parameters

param x

An angle, in radians

returns

method double Asin (double x) Source #

Calculates an arcsine.

Parameters

param x

The value for which an arcsine is to be calculated.

returns

, in radians.

method double Acos (double x) Source #

Calculates an arc-cosine.

Parameters

param x

The value for which an arc-cosine is to be calculated

returns

, in radians

method double Atan (double x) Source #

Calculates an arc-tangent.

Parameters

param x

The value for which an arc-tangent is to be calculated

returns

, in radians

method double Sinh (double x) Source #

Calculates a hyperbolic sine.

Parameters

param x

The value for which a hyperbolic sine is to be calculated

returns

method double Cosh (double x) Source #

Calculates a hyperbolic cosine.

Parameters

param x

The value for which a hyperbolic cosine is to be calculated

returns

method double Tanh (double x) Source #

Calculates a hyperbolic tangent.

Parameters

param x

The value for which a hyperbolic tangent is to be calculated.

returns

method double Asinh (double x) Source #

Calculates an area hyperbolic sine

Parameters

param x

The value for which an area hyperbolic sine is to be calculated.

returns

.

method double Acosh (double x) Source #

Calculates an area hyperbolic cosine.

Parameters

param x

The value for which an area hyperbolic cosine is to be calculated.

returns

.

method double Atanh (double x) Source #

Calculates an area hyperbolic tangent.

Parameters

param x

The value for which an area hyperbolic tangent is to be calculated.

returns

method double Negate (double x) Source #

Negate the value

Parameters

param x

Value to negate

returns

The negated source value

method double Append (double x, double y) Source #

Semigroup append (sum)

Parameters

param x

left hand side of the append operation

param y

right hand side of the append operation

returns

x + y

method double Empty () Source #

Zero

method int GetHashCode (double x) Source #

Get the hash-code of the provided value

Parameters

returns

Hash code of x

method Task<bool> EqualsAsync (double x, double y) Source #

method Task<int> GetHashCodeAsync (double x) Source #

method Task<int> CompareAsync (double x, double y) Source #

struct TFloat Source #

Fields

Methods

method bool Equals (float x, float y) Source #

Equality test

Parameters

param x

Left hand side of the equality operation

param y

Right hand side of the equality operation

returns

True if parameters are equal

method int Compare (float x, float y) Source #

Compare two values

Parameters

param x

Left hand side of the compare operation

param y

Right hand side of the compare operation

returns

if x greater than y : 1

if x less than y : -1

if x equals y : 0

method float Plus (float x, float y) Source #

Find the sum of two values

Parameters

param x

left hand side of the addition operation

param y

right hand side of the addition operation

returns

The sum of x and y

method float Subtract (float x, float y) Source #

Find the difference between two values

Parameters

param x

left hand side of the subtraction operation

param y

right hand side of the subtraction operation

returns

The difference between x and y

method float Product (float x, float y) Source #

Find the product of two values

Parameters

param x

left hand side of the product operation

param y

right hand side of the product operation

returns

The product of x and y

method float Divide (float x, float y) Source #

Divide two numbers

Parameters

param x

left hand side of the division operation

param y

right hand side of the division operation

returns

x / y

method float Abs (float x) Source #

Find the absolute value of a number

Parameters

param x

The value to find the absolute value of

returns

The non-negative absolute value of x

method float Signum (float x) Source #

Find the sign of x

Parameters

param x

The value to find the sign of

returns

-1, 0, or +1

method float FromInteger (int x) Source #

Generate a numeric value from an integer

Parameters

param x

The integer to use

returns

The equivalent of x in the Num

method float FromDecimal (decimal x) Source #

Generate a numeric value from a decimal

Parameters

param x

The decimal to use

returns

The equivalent of x in the Num

method float FromFloat (float x) Source #

Generate a numeric value from a float

Parameters

param x

The float to use

returns

The equivalent of x in the Num

method float FromDouble (double x) Source #

Generate a numeric value from a double

Parameters

param x

The double to use

returns

The equivalent of x in the Num

method float FromRational (Ratio<int> x) Source #

Generates a fractional value from an integer ratio.

Parameters

param x

The ratio to convert

returns

The equivalent of x in the implementing type.

method float Pi () Source #

Returns an approximation of pi.

Parameters

returns

A reasonable approximation of pi in this type

method float Exp (float x) Source #

The exponential function.

Parameters

param x

The value for which we are calculating the exponential

returns

method float Sqrt (float x) Source #

Calculates the square root of a value.

Parameters

param x

The value for which we are calculating the square root.

returns

.

method float Log (float x) Source #

Calculates the natural logarithm of a value.

Parameters

param x

The value for which we are calculating the natural logarithm.

returns

.

method float Pow (float x, float y) Source #

Raises x to the power y

Parameters

param x

The base to be raised to y

param y

The exponent to which we are raising x

returns

.

method float LogBase (float b, float x) Source #

Calculates the logarithm of a value with respect to an arbitrary base.

Parameters

param x

The base to use for the logarithm of t

param y

The value for which we are calculating the logarithm.

returns

.

method float Sin (float x) Source #

Calculates the sine of an angle.

Parameters

param x

An angle, in radians

returns

method float Cos (float x) Source #

Calculates the cosine of an angle.

Parameters

param x

An angle, in radians

returns

method float Tan (float x) Source #

Calculates the tangent of an angle.

Parameters

param x

An angle, in radians

returns

method float Asin (float x) Source #

Calculates an arcsine.

Parameters

param x

The value for which an arcsine is to be calculated.

returns

, in radians.

method float Acos (float x) Source #

Calculates an arc-cosine.

Parameters

param x

The value for which an arc-cosine is to be calculated

returns

, in radians

method float Atan (float x) Source #

Calculates an arc-tangent.

Parameters

param x

The value for which an arc-tangent is to be calculated

returns

, in radians

method float Sinh (float x) Source #

Calculates a hyperbolic sine.

Parameters

param x

The value for which a hyperbolic sine is to be calculated

returns

method float Cosh (float x) Source #

Calculates a hyperbolic cosine.

Parameters

param x

The value for which a hyperbolic cosine is to be calculated

returns

method float Tanh (float x) Source #

Calculates a hyperbolic tangent.

Parameters

param x

The value for which a hyperbolic tangent is to be calculated.

returns

method float Asinh (float x) Source #

Calculates an area hyperbolic sine

Parameters

param x

The value for which an area hyperbolic sine is to be calculated.

returns

.

method float Acosh (float x) Source #

Calculates an area hyperbolic cosine.

Parameters

param x

The value for which an area hyperbolic cosine is to be calculated.

returns

.

method float Atanh (float x) Source #

Calculates an area hyperbolic tangent.

Parameters

param x

The value for which an area hyperbolic tangent is to be calculated.

returns

method float Negate (float x) Source #

Negate the value

Parameters

param x

Value to negate

returns

The negated source value

method float Append (float x, float y) Source #

Semigroup append (sum)

Parameters

param x

left hand side of the append operation

param y

right hand side of the append operation

returns

x + y

method float Empty () Source #

Zero

method int GetHashCode (float x) Source #

Get the hash-code of the provided value

Parameters

returns

Hash code of x

method Task<bool> EqualsAsync (float x, float y) Source #

method Task<int> GetHashCodeAsync (float x) Source #

method Task<int> CompareAsync (float x, float y) Source #

struct TInt Source #

Integer number

Fields

Methods

method bool Equals (int x, int y) Source #

Equality test

Parameters

param x

The left hand side of the equality operation

param y

The right hand side of the equality operation

returns

True if x and y are equal

method int Compare (int x, int y) Source #

Compare two values

Parameters

param x

Left hand side of the compare operation

param y

Right hand side of the compare operation

returns

if x greater than y : 1

if x less than y : -1

if x equals y : 0

method int Plus (int x, int y) Source #

Find the sum of two numbers

Parameters

param x

left hand side of the addition operation

param y

right hand side of the addition operation

returns

The sum of x and y

method int Subtract (int x, int y) Source #

Find the difference between two values

Parameters

param x

left hand side of the subtraction operation

param y

right hand side of the subtraction operation

returns

The difference between x and y

method int Product (int x, int y) Source #

Find the product of two numbers

Parameters

param x

left hand side of the product operation

param y

right hand side of the product operation

returns

The product of x and y

method int Divide (int x, int y) Source #

Divide two numbers

Parameters

param x

left hand side of the division operation

param y

right hand side of the division operation

returns

x / y

method int Abs (int x) Source #

Find the absolute value of a number

Parameters

param x

The value to find the absolute value of

returns

The non-negative absolute value of x

method int Signum (int x) Source #

Find the sign of x

Parameters

param x

The value to find the sign of

returns

-1, 0, or +1

method int FromInteger (int x) Source #

Generate a numeric value from an integer

Parameters

param x

The integer to use

returns

The equivalent of x in the Num

method int FromDecimal (decimal x) Source #

Generate a numeric value from a float

Parameters

param x

The float to use

returns

The equivalent of x in the Num

method int FromFloat (float x) Source #

Generate a numeric value from a double

Parameters

param x

The double to use

returns

The equivalent of x in the Num

method int FromDouble (double x) Source #

Generate a numeric value from a decimal

Parameters

param x

The decimal to use

returns

The equivalent of x in the Num

method int Empty () Source #

Monoid empty value (0)

Parameters

returns

0

method int Negate (int x) Source #

Negate the value

Parameters

param x

Value to negate

returns

The negated source value

method int Append (int x, int y) Source #

Semigroup append (sum)

Parameters

param x

left hand side of the append operation

param y

right hand side of the append operation

returns

x + y

method int GetHashCode (int x) Source #

Get the hash-code of the provided value

Parameters

returns

Hash code of x

method int True () Source #

Returns True

Parameters

returns

True

method int False () Source #

Returns False

Parameters

returns

False

method int And (int a, int b) Source #

Returns the result of the bitwise AND operation between a and b

Parameters

returns

The result of the bitwise AND operation between a and b

method int Or (int a, int b) Source #

Returns the result of the bitwise OR operation between a and b

Parameters

returns

The result of the bitwise OR operation between a and b

method int Not (int a) Source #

Returns the result of the bitwise NOT operation on a

Parameters

returns

The result of the bitwise NOT operation on a

method int XOr (int a, int b) Source #

Returns the result of the bitwise exclusive-OR operation between a and b

Parameters

returns

The result of the bitwise exclusive-OR operation between a and b

method int Implies (int a, int b) Source #

Logical implication

Parameters

returns

If a is true that implies b, else true

method int BiCondition (int a, int b) Source #

Bitwise bi-conditional.

Parameters

returns

Not(XOr(a, b))

method Task<bool> EqualsAsync (int x, int y) Source #

method Task<int> GetHashCodeAsync (int x) Source #

method Task<int> CompareAsync (int x, int y) Source #

struct TLong Source #

Long integer number

Fields

Methods

method bool Equals (long x, long y) Source #

Equality test

Parameters

param x

The left hand side of the equality operation

param y

The right hand side of the equality operation

returns

True if x and y are equal

method int Compare (long x, long y) Source #

Compare two values

Parameters

param x

Left hand side of the compare operation

param y

Right hand side of the compare operation

returns

if x greater than y : 1

if x less than y : -1

if x equals y : 0

method long Plus (long x, long y) Source #

Find the sum of two numbers

Parameters

param x

left hand side of the addition operation

param y

right hand side of the addition operation

returns

The sum of x and y

method long Subtract (long x, long y) Source #

Find the difference between two values

Parameters

param x

left hand side of the subtraction operation

param y

right hand side of the subtraction operation

returns

The difference between x and y

method long Product (long x, long y) Source #

Fund the product of two numbers

Parameters

param x

left hand side of the product operation

param y

right hand side of the product operation

returns

The product of x and y

method long Divide (long x, long y) Source #

Divide x by y

Parameters

param x

left hand side of the division operation

param y

right hand side of the division operation

returns

x / y

method long Abs (long x) Source #

Find the absolute value of a number

Parameters

param x

The value to find the absolute value of

returns

The non-negative absolute value of x

method long Signum (long x) Source #

Find the sign of x

Parameters

param x

The value to find the sign of

returns

-1, 0, or +1

method long FromInteger (int x) Source #

Generate a numeric value from an integer

Parameters

param x

The integer to use

returns

The equivalent of x in the Num

method long FromDecimal (decimal x) Source #

Generate a numeric value from a float

Parameters

param x

The float to use

returns

The equivalent of x in the Num

method long FromFloat (float x) Source #

Generate a numeric value from a double

Parameters

param x

The double to use

returns

The equivalent of x in the Num

method long FromDouble (double x) Source #

Generate a numeric value from a decimal

Parameters

param x

The decimal to use

returns

The equivalent of x in the Num

method long Append (long x, long y) Source #

Semigroup append (sum)

Parameters

param x

left hand side of the append operation

param y

right hand side of the append operation

returns

x + y

method long Negate (long x) Source #

Negate the value

Parameters

param x

Value to negate

returns

The negated source value

method long Empty () Source #

Zero

method int GetHashCode (long x) Source #

Get the hash-code of the provided value

Parameters

returns

Hash code of x

method long True () Source #

Returns True

Parameters

returns

True

method long False () Source #

Returns False

Parameters

returns

False

method long And (long a, long b) Source #

Returns the result of the bitwise AND operation between a and b

Parameters

returns

The result of the bitwise AND operation between a and b

method long Or (long a, long b) Source #

Returns the result of the bitwise OR operation between a and b

Parameters

returns

The result of the bitwise OR operation between a and b

method long Not (long a) Source #

Returns the result of the bitwise NOT operation on a

Parameters

returns

The result of the bitwise NOT operation on a

method long XOr (long a, long b) Source #

Returns the result of the bitwise exclusive-OR operation between a and b

Parameters

returns

The result of the bitwise exclusive-OR operation between a and b

method long Implies (long a, long b) Source #

Logical implication

Parameters

returns

If a is true that implies b, else true

method long BiCondition (long a, long b) Source #

Bitwise bi-conditional.

Parameters

returns

Not(XOr(a, b))

method Task<bool> EqualsAsync (long x, long y) Source #

method Task<int> GetHashCodeAsync (long x) Source #

method Task<int> CompareAsync (long x, long y) Source #

struct TLst <A> Source #

Fields

Methods

method Lst<A> Append (Lst<A> x, Lst<A> y) Source #

method Lst<A> Subtract (Lst<A> x, Lst<A> y) Source #

method Lst<A> Empty () Source #

struct TNumericChar Source #

Integer number

Fields

Methods

method bool Equals (char x, char y) Source #

Equality test

Parameters

param x

The left hand side of the equality operation

param y

The right hand side of the equality operation

returns

True if x and y are equal

method int Compare (char x, char y) Source #

Compare two values

Parameters

param x

Left hand side of the compare operation

param y

Right hand side of the compare operation

returns

if x greater than y : 1

if x less than y : -1

if x equals y : 0

method char Empty () Source #

Monoid empty value (0)

Parameters

returns

0

method char Append (char x, char y) Source #

Semigroup append (sum)

Parameters

param x

left hand side of the append operation

param y

right hand side of the append operation

returns

x + y

method int GetHashCode (char x) Source #

Get the hash-code of the provided value

Parameters

returns

Hash code of x

method char Plus (char x, char y) Source #

method char Subtract (char x, char y) Source #

method char Product (char x, char y) Source #

method char Negate (char x) Source #

method Task<bool> EqualsAsync (char x, char y) Source #

method Task<int> GetHashCodeAsync (char x) Source #

method Task<int> CompareAsync (char x, char y) Source #

struct TShort Source #

Short integer number

Fields

Methods

method bool Equals (short x, short y) Source #

Equality test

Parameters

param x

The left hand side of the equality operation

param y

The right hand side of the equality operation

returns

True if x and y are equal

method int Compare (short x, short y) Source #

Compare two values

Parameters

param x

Left hand side of the compare operation

param y

Right hand side of the compare operation

returns

if x greater than y : 1

if x less than y : -1

if x equals y : 0

method short Plus (short x, short y) Source #

Find the sum of two numbers

Parameters

param x

left hand side of the addition operation

param y

right hand side of the addition operation

returns

The sum of x and y

method short Subtract (short x, short y) Source #

Find the difference between two values

Parameters

param x

left hand side of the subtraction operation

param y

right hand side of the subtraction operation

returns

The difference between x and y

method short Product (short x, short y) Source #

Fund the product of two numbers

Parameters

param x

left hand side of the product operation

param y

right hand side of the product operation

returns

The product of x and y

method short Divide (short x, short y) Source #

Divide x by y

Parameters

param x

left hand side of the division operation

param y

right hand side of the division operation

returns

x / y

method short Abs (short x) Source #

Find the absolute value of a number

Parameters

param x

The value to find the absolute value of

returns

The non-negative absolute value of x

method short Signum (short x) Source #

Find the sign of x

Parameters

param x

The value to find the sign of

returns

-1, 0, or +1

method short FromInteger (int x) Source #

Generate a numeric value from an integer

Parameters

param x

The integer to use

returns

The equivalent of x in the Num

method short FromDecimal (decimal x) Source #

Generate a numeric value from a float

Parameters

param x

The float to use

returns

The equivalent of x in the Num

method short FromFloat (float x) Source #

Generate a numeric value from a double

Parameters

param x

The double to use

returns

The equivalent of x in the Num

method short FromDouble (double x) Source #

Generate a numeric value from a decimal

Parameters

param x

The decimal to use

returns

The equivalent of x in the Num

method short Negate (short x) Source #

Negate the value

Parameters

param x

Value to negate

returns

The negated source value

method short Append (short x, short y) Source #

Semigroup append (sum)

Parameters

param x

left hand side of the append operation

param y

right hand side of the append operation

returns

x + y

method short Empty () Source #

Zero

method int GetHashCode (short x) Source #

Get the hash-code of the provided value

Parameters

returns

Hash code of x

method short True () Source #

Returns True

Parameters

returns

True

method short False () Source #

Returns False

Parameters

returns

False

method short And (short a, short b) Source #

Returns the result of the bitwise AND operation between a and b

Parameters

returns

The result of the bitwise AND operation between a and b

method short Or (short a, short b) Source #

Returns the result of the bitwise OR operation between a and b

Parameters

returns

The result of the bitwise OR operation between a and b

method short Not (short a) Source #

Returns the result of the bitwise NOT operation on a

Parameters

returns

The result of the bitwise NOT operation on a

method short XOr (short a, short b) Source #

Returns the result of the bitwise exclusive-OR operation between a and b

Parameters

returns

The result of the bitwise exclusive-OR operation between a and b

method short Implies (short a, short b) Source #

Logical implication

Parameters

returns

If a is true that implies b, else true

method short BiCondition (short a, short b) Source #

Bitwise bi-conditional.

Parameters

returns

Not(XOr(a, b))

method Task<bool> EqualsAsync (short x, short y) Source #

method Task<int> GetHashCodeAsync (short x) Source #

method Task<int> CompareAsync (short x, short y) Source #

struct TString Source #

Fields

Methods

method string Append (string x, string y) Source #

Append

method string Empty () Source #

Empty

Parameters

returns

method bool Equals (string x, string y) Source #

Equality test

Parameters

param x

The left hand side of the equality operation

param y

The right hand side of the equality operation

returns

True if x and y are equal

method int Compare (string x, string y) Source #

Compare two values

Parameters

param x

Left hand side of the compare operation

param y

Right hand side of the compare operation

returns

if x greater than y : 1

if x less than y : -1

if x equals y : 0

method int GetHashCode (string x) Source #

Get the hash-code of the provided value

Parameters

returns

Hash code of x

method Task<bool> EqualsAsync (string x, string y) Source #

method Task<int> GetHashCodeAsync (string x) Source #

method Task<int> CompareAsync (string x, string y) Source #

struct TStringOrdinalIgnoreCase Source #

Fields

field TStringOrdinalIgnoreCase Inst = default(TStringOrdinalIgnoreCase) Source #

Methods

method string Append (string x, string y) Source #

Append

method string Empty () Source #

Empty

Parameters

returns

method bool Equals (string x, string y) Source #

Equality test

Parameters

param x

The left hand side of the equality operation

param y

The right hand side of the equality operation

returns

True if x and y are equal

method int Compare (string x, string y) Source #

Compare two values

Parameters

param x

Left hand side of the compare operation

param y

Right hand side of the compare operation

returns

if x greater than y : 1

if x less than y : -1

if x equals y : 0

method int GetHashCode (string x) Source #

Get the hash-code of the provided value

Parameters

returns

Hash code of x

method Task<bool> EqualsAsync (string x, string y) Source #

method Task<int> GetHashCodeAsync (string x) Source #

method Task<int> CompareAsync (string x, string y) Source #

struct TStringOrdinal Source #

Fields

Methods

method string Append (string x, string y) Source #

Append

method string Empty () Source #

Empty

Parameters

returns

method bool Equals (string x, string y) Source #

Equality test

Parameters

param x

The left hand side of the equality operation

param y

The right hand side of the equality operation

returns

True if x and y are equal

method int Compare (string x, string y) Source #

Compare two values

Parameters

param x

Left hand side of the compare operation

param y

Right hand side of the compare operation

returns

if x greater than y : 1

if x less than y : -1

if x equals y : 0

method int GetHashCode (string x) Source #

Get the hash-code of the provided value

Parameters

returns

Hash code of x

method Task<bool> EqualsAsync (string x, string y) Source #

method Task<int> GetHashCodeAsync (string x) Source #

method Task<int> CompareAsync (string x, string y) Source #

struct TStringCurrentCultureIgnoreCase Source #

Fields

field TStringCurrentCultureIgnoreCase Inst = default(TStringCurrentCultureIgnoreCase) Source #

Methods

method string Append (string x, string y) Source #

Append

method string Empty () Source #

Empty

Parameters

returns

method bool Equals (string x, string y) Source #

Equality test

Parameters

param x

The left hand side of the equality operation

param y

The right hand side of the equality operation

returns

True if x and y are equal

method int Compare (string x, string y) Source #

Compare two values

Parameters

param x

Left hand side of the compare operation

param y

Right hand side of the compare operation

returns

if x greater than y : 1

if x less than y : -1

if x equals y : 0

method int GetHashCode (string x) Source #

Get the hash-code of the provided value

Parameters

returns

Hash code of x

method Task<bool> EqualsAsync (string x, string y) Source #

method Task<int> GetHashCodeAsync (string x) Source #

method Task<int> CompareAsync (string x, string y) Source #

struct TStringCurrentCulture Source #

Fields

field TStringCurrentCulture Inst = default(TStringCurrentCulture) Source #

Methods

method string Append (string x, string y) Source #

Append

method string Empty () Source #

Empty

Parameters

returns

method bool Equals (string x, string y) Source #

Equality test

Parameters

param x

The left hand side of the equality operation

param y

The right hand side of the equality operation

returns

True if x and y are equal

method int Compare (string x, string y) Source #

Compare two values

Parameters

param x

Left hand side of the compare operation

param y

Right hand side of the compare operation

returns

if x greater than y : 1

if x less than y : -1

if x equals y : 0

method int GetHashCode (string x) Source #

Get the hash-code of the provided value

Parameters

returns

Hash code of x

method Task<bool> EqualsAsync (string x, string y) Source #

method Task<int> GetHashCodeAsync (string x) Source #

method Task<int> CompareAsync (string x, string y) Source #